package client.core.validation;

import javax.swing.JTextField;

public class Validator {
	
	private JTextField obj;
	private AbstractMatcher  match;
	
	public Validator(JTextField obj, AbstractMatcher  match){
		this.obj = obj;
		this.match = match;
	}
	
	public boolean isValid(){
		return match.checkIsValid(obj.getText());
	}
	
}
